Skip to content

formal/agda: pin Agda 2.7.0.1; prove usability from --cubical (agda/cubical v0.8) - #861

Merged
hyperpolymath merged 3 commits into
mainfrom
claude/agda-2.7.0.1-cubical
Dec 2, 2026
Merged

hyperpolymath merged 3 commits into
mainfrom
claude/agda-2.7.0.1-cubical

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Owner decision (relayed): install Agda 2.7.0.1 plus the latest compatible agda/cubical, recheck formal/agda/, and show the proofs fit the estate's Agda scheme.

Pins

Agda 2.7.0.1, official static binary Agda-v2.7.0.1-linux.tar.xz (agda/agda tag v2.7.0.1, commit a6fc20c2…). SHA-256 975b515a14877ab6bce5bfc641e16c4a3ee52ca5d7f846577dee80aa2145db8a, verified in CI before unpacking.
agda/cubical v0.8, commit 3291fc1d8cae1409cc54d4f9cca7366158b573d7. cubical's README pairs v0.8 with 2.6.4.1/2.7.0.1; v0.9 and master need Agda 2.8.0. Fetched by SHA, HEAD asserted.

Results (Agda 2.7.0.1)

  • QttSemiring.agda, BorrowProvenance.agda: exit 0, no warnings, under --safe --without-K --cubical-compatible. No repairs needed. No proof or statement text changed.
  • check-agda-controls: all 5 planted failures still fail. The indexed control still fails because 2.7.0.1 prints UnsupportedIndexedMatch, and the gate rejects that output.
  • New formal/agda-cubical/CubicalCompat.agda (--safe --cubical, depends on cubical-0.8) imports both modules and re-exports theorems from each. It also uses them as cubical Paths via eqToPath/pathToEq, including a funext path between qplus and its flip. It checks clean.
  • check-agda-cubical-controls: 5 planted failures, each fails. One is a source that drops --cubical-compatible; Agda refuses it with "Importing module QttSemiring not using the --cubical-compatible flag from a module which does". Another is a module the fixture doesn't import. So the check is load-bearing, and new theory modules must join the fixture.
  • The whole CI job was replayed locally from a fresh download and a fresh cubical fetch, and all 4 recipes passed.

Decision: stay --cubical-compatible

Nothing was ported to full --cubical. --cubical-compatible is the flag that makes a module importable from cubical code, so the import itself proves usability. Porting would leave the PROOF-POLICY theory lane, add a library to the import cone, and cut the Rocq/Lean legs for cubical-primitive statements. Rationale is in formal/agda/README.adoc.

CI

agda-proofs job (coq-proof-gate.yml) now uses the pinned binary and cubical, and runs 4 recipes. No uses: ref changed, so actions.lock is unchanged and check-actions-lock.sh passes.

Not established / honest limits

  • Still ungraded: no receipt, no Lean leg.
  • The binary digest is trust-on-first-use. The agda/agda release page and API weren't reachable from the session, so the digest wasn't compared with GitHub's published asset digest. Worth confirming by someone with access.
  • The nine BorrowProvenance mutations were not rerun on 2.7.0.1.
  • just check: lint and dune runtest (849 tests) pass. guard fails at check-soundness-ledger.sh with anchor drift. That failure reproduces on clean origin/main and is being repaired in fix(soundness): restore the #833 ledger row and drop a stale anchor (main is red) #860, which this PR doesn't touch.

Commit is unsigned; owner to re-sign.


Generated by Claude Code

…l v0.8)

Agda 2.7.0.1 (the estate pin) replaces Ubuntu's 2.6.3 in the agda-proofs CI
job: the official static release binary, SHA-256 pinned and verified before
unpack (975b515a…db8a). Both theory modules check unchanged on 2.7.0.1 under
--safe --without-K --cubical-compatible with no diagnostic; no proof or
statement text changed. The five planted controls still fail the gate.

New: formal/agda-cubical/CubicalCompat.agda, a --safe --cubical module in its
own library depending on agda/cubical v0.8 (commit 3291fc1d…, the last
release supporting 2.7.0.1; v0.9 needs 2.8.0). It imports every module under
formal/agda/, re-exports theorems from each, and uses them as Paths via
eqToPath (including a funext path for qplus). New recipes
check-agda-cubical and check-agda-cubical-controls (5 planted failures,
including a source that drops --cubical-compatible, which Agda refuses).
Sources stay at --cubical-compatible; README records why and the pins.

Still ungraded: no receipt, no Lean leg; the binary's digest is TOFU.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J4QvDfHidNin3g7itrbLfk
@gitnotebooks

gitnotebooks Bot commented Dec 1, 2026

Copy link
Copy Markdown

@coderabbitai

coderabbitai Bot commented Dec 1, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 59 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 9a1b6e9d-e3fe-4c89-bab0-53c583c34f2c
Commits

Reviewing files that changed from the base of the PR and between 745e063 and d538e0c.

Files selected for processing: 7

  • .github/workflows/coq-proof-gate.yml
  • .gitignore
  • formal/agda-cubical/CubicalCompat.agda
  • formal/agda-cubical/affinescript-cubical-compat.agda-lib
  • formal/agda/BORROW-PROVENANCE-EXPERIMENT.adoc
  • formal/agda/README.adoc
  • formal/justfile
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

SonarCloud githubactions:S6506 on PR #861: curl -L could follow a
redirect to a non-HTTPS URL. The SHA-256 check already guards the file's
integrity; this also closes the transport path.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J4QvDfHidNin3g7itrbLfk

hyperpolymath commented Dec 1, 2026 •

Copy link
Copy Markdown
Owner Author

build fails only at Soundness-ledger anti-staleness gate (tools/check-soundness-ledger.sh): anchor drift for test/test_interp_eval.ml and test/test_intrinsic_shadow.ml against tools/soundness-anchors.sha256. Every other step of the job passes, including all tests.

This isn't caused by this PR:

  • It reproduces on clean origin/main (464f7c6). I ran the script on a stashed tree and got exit 1 with the same drift.
  • This PR touches only formal/, .gitignore and coq-proof-gate.yml. It doesn't touch any test, docs/SOUNDNESS.adoc or the anchors file.

The ledger repair is in #856. Once that merges, merging main into this branch should clear it. I'm deliberately not re-sealing the anchors here.


Generated by Claude Code

@hyperpolymath
hyperpolymath marked this pull request as ready for review December 2, 2026 15:19
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Dec 2, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-12-02T15:22:05.485924Z d538e0c Draft marked ready
🔒 Security Review ✅ Completed 2026-12-02T15:21:53.338349Z d538e0c Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@hyperpolymath
hyperpolymath merged commit 8f2b80d into main Dec 2, 2026
17 checks passed
@hyperpolymath
hyperpolymath deleted the claude/agda-2.7.0.1-cubical branch December 2, 2026 15:19
@sonarqubecloud

sonarqubecloud Bot commented Dec 2, 2026

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants